@echo off
chcp 65001 >nul

type main.bat | find "version" > ver.bat
call ver.bat > nul

set myvision=%version%
echo.当前版本%myvision%
 
rem 设置服务器网址
set url=https://gitee.com/xish-cc/MWTool/raw/master/cmd/MWTool.cmd

curl -s %url% | find "version" > ver.bat
call ver.bat > nul

echo.最新版本%version% 
echo.
echo.

del ver.bat

if %myvision% neq %version% curl -s %url% > main.bat &&color 0A

start main.bat

exit